package com.xzr2;

public class BankOfDalian  extends Bank{
    double year;

    @Override
    double computerInterest() {
        super.year = (int)year;
        super.computerInterest();
        int day = (int)((year - super.year)*1000);
        interest += day * rate / 365 *savedMoney;
        System.out.println(savedMoney + "元在大连银行" + super.year + "年" + day + "天的利息：" + interest + "元" );
        return interest;
    }

    public double getYear() {
        return year;
    }

    public void setYear(double year) {
        this.year = year;
    }
}
